package com.hhs.storage.bean;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * <p>
 *
 * </p>
 *
 * @author hhs
 * @since 2023-06-13
 */
@Data
public class Notepad implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    private String content;
    /**
     * 状态 0 不重要 1重要
     */
    private Integer importantFlag;

    /**
     * 状态 0 未完成 1已完成
     */
    private Integer state;

    /**
     * 排序值起始值为0
     */
    private Integer sortKey;

    private String creater;
    @JSONField(format="yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;


    @JSONField(format="yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private LocalDate remindDate;
    //有又用上了
    @TableField(exist = false)
    private List<ProjectWorkFlow> subWk=new ArrayList<>();

    @JSONField(format="yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @TableField(exist = false)
    private LocalDate createTimeStartTime;

    @TableField(exist = false)
    private String searchTime;
    //是否有工序
    @TableField(exist = false)
    private Boolean flagWk;
    //是否有完整信息
    @TableField(exist = false)
    private Boolean flagFull;
    //补充信息
    @TableField(exist = false)
    private Map<String,Object> otherInfo=new HashMap();
}
